Pantry Order Management Page and Confirm Delivery Modal#116
Pantry Order Management Page and Confirm Delivery Modal#116
Conversation
sam-schu
left a comment
There was a problem hiding this comment.
- It looks like we're missing Filter, unless Priya said we don't need that?
- For the modals, can we create the component once and just vary the data passed in/displayed depending on which order is selected, rather than creating one modal instance per order?
apps/frontend/src/components/forms/orderReceivedActionModal.tsx
Outdated
Show resolved
Hide resolved
apps/frontend/src/components/forms/orderReceivedActionModal.tsx
Outdated
Show resolved
Hide resolved
|
sam-schu
left a comment
There was a problem hiding this comment.
When I try to confirm delivery with photos I'm getting the following error, can you check to see if it's the same for you? it might be a config issue on my end
Detailed AWS upload error: PermanentRedirect: The bucket you are attempting to access must be addressed using the specified endpoint. Please send all future requests to this endpoint.
at ProtocolLib.getErrorSchemaOrThrowBaseException (C:\Users\short\GitHub\ssf\node_modules\@aws-sdk\core\dist-cjs\submodules\protocols\index.js:69:67)
at AwsRestXmlProtocol.handleError (C:\Users\short\GitHub\ssf\node_modules\@aws-sdk\core\dist-cjs\submodules\protocols\index.js:1810:65)
at AwsRestXmlProtocol.deserializeResponse (C:\Users\short\GitHub\ssf\node_modules\@smithy\core\dist-cjs\submodules\protocols\index.js:314:24)
at processTicksAndRejections (node:internal/process/task_queues:103:5)
at C:\Users\short\GitHub\ssf\node_modules\@smithy\core\dist-cjs\submodules\schema\index.js:26:24
at C:\Users\short\GitHub\ssf\node_modules\@aws-sdk\middleware-sdk-s3\dist-cjs\index.js:386:20
at C:\Users\short\GitHub\ssf\node_modules\@smithy\middleware-retry\dist-cjs\index.js:254:46
at C:\Users\short\GitHub\ssf\node_modules\@aws-sdk\middleware-flexible-checksums\dist-cjs\index.js:241:24
at C:\Users\short\GitHub\ssf\node_modules\@aws-sdk\middleware-sdk-s3\dist-cjs\index.js:63:28
at C:\Users\short\GitHub\ssf\node_modules\@aws-sdk\middleware-sdk-s3\dist-cjs\index.js:90:20 {
'$fault': 'client',
'$retryable': undefined,
'$metadata': {
httpStatusCode: 301,
requestId: '4BHVNFYC5VQTXNTJ',
extendedRequestId: 'EnfjEyXkfUIkcbtXqIPhCmz/Hi89Y7ZjweH5xA+aV7eFDWtfq97curj7XYEs8o2bzFrmQ4yc5dwrrXDib9J0lW/ZZbH7w1qh',
cfId: undefined,
attempts: 1,
totalRetryDelay: 0
},
Code: 'PermanentRedirect',
Endpoint: 'confirm-delivery-photos.s3.us-east-2.amazonaws.com',
Bucket: 'confirm-delivery-photos',
RequestId: '4BHVNFYC5VQTXNTJ',
HostId: 'EnfjEyXkfUIkcbtXqIPhCmz/Hi89Y7ZjweH5xA+aV7eFDWtfq97curj7XYEs8o2bzFrmQ4yc5dwrrXDib9J0lW/ZZbH7w1qh'
}
[Nest] 38604 - 03/11/2026, 3:31:54 PM ERROR [ExceptionsHandler] File upload to AWS failed
Error: File upload to AWS failed
at AWSS3Service.upload (C:\Users\short\GitHub\ssf\dist\apps\backend\main.js:4256:19)
at processTicksAndRejections (node:internal/process/task_queues:103:5)
at OrdersController.confirmDelivery (C:\Users\short\GitHub\ssf\dist\apps\backend\main.js:4011:19)
apps/frontend/src/components/forms/deliveryConfirmationModal.tsx
Outdated
Show resolved
Hide resolved
apps/frontend/src/components/forms/orderReceivedActionModal.tsx
Outdated
Show resolved
Hide resolved
apps/frontend/src/components/forms/orderReceivedActionModal.tsx
Outdated
Show resolved
Hide resolved
Confirming a delivery with photos works just fine for me, I'm not sure what's going on here... |
You guys have AWS services across multiple regions (ie cognito in us-east-1 and s3 in us-east-2). My guess would be that Justin's is working because he is relying on the default cases, while Sam has a region for AWS set in his env file. I would suggest deleting the bucket in us-east-2 and recreating it in us-east-1 to be consistent |
swarkewalia
left a comment
There was a problem hiding this comment.
looks great! just some cleanup:
- Can we reset the fields for the confirm order delivery modal? currently the fields dont reset when i close the modal and open a new one.
- Currently the minimum value for month and day are both 1, but the same is for year so i can submit a delivery for the year 1 - can we change the validation so it only allows you to submit dates that are on or after the date the order was created?
swarkewalia
left a comment
There was a problem hiding this comment.
everything looks good! just one small thing - can we also restrict 'date received' dates so the user cannot enter a date after the current date?
apps/frontend/src/components/forms/orderReceivedActionModal.tsx
Outdated
Show resolved
Hide resolved
sam-schu
left a comment
There was a problem hiding this comment.
- Is it possible to make the columns align across the 3 different tables even if the window width is relatively small? (ignore if this is not trivial)
- It looks like the pending and shipped rows are swapped compared to the design
- Can we add a space around the dates hyphen like in the design?
sam-schu
left a comment
There was a problem hiding this comment.
Good to merge after 2 small comments!
| return data as FoodRequest[]; | ||
| } | ||
|
|
||
| public async confirmDelivery( |
There was a problem hiding this comment.
I think this made it back in accidentally on merge
| textDecoration="underline" | ||
| onClick={() => onOrderSelectForAction(order)} | ||
| > | ||
| Complete Required Action |
There was a problem hiding this comment.
I don't think the font is the right color for this
ℹ️ Issue
Closes https://vidushimisra.atlassian.net/jira/software/projects/SSF/boards/1/backlog?jql=assignee%20%3D%20712020%3A10ef9ad9-e290-4bbd-8c4b-cb215e8d449a&selectedIssue=SSF-142
📝 Description
I refactored the frontend for the pantry order management page to match the Figma design. I also implemented the confirm order delivery modal, which features calling the confirmDelivery route. This modal is a form that involves uploading pictures to send.
Notable frontend route: /pantry-order-management
✔️ Verification
I verified the frontend matched the figma design. I also verified confirm delivery works as expected with making sure the date, feedback and pictures show up in the database.
🏕️ (Optional) Future Work / Notes
Notes: The assignee functionality is purposefully not present.